Integrand size = 24, antiderivative size = 177 \[ \int \frac {\sin ^9(c+d x)}{a-b \sin ^4(c+d x)} \, dx=-\frac {a^{3/2} \arctan \left (\frac {\sqrt [4]{b} \cos (c+d x)}{\sqrt {\sqrt {a}-\sqrt {b}}}\right )}{2 \sqrt {\sqrt {a}-\sqrt {b}} b^{9/4} d}-\frac {a^{3/2} \text {arctanh}\left (\frac {\sqrt [4]{b} \cos (c+d x)}{\sqrt {\sqrt {a}+\sqrt {b}}}\right )}{2 \sqrt {\sqrt {a}+\sqrt {b}} b^{9/4} d}+\frac {(a+b) \cos (c+d x)}{b^2 d}-\frac {2 \cos ^3(c+d x)}{3 b d}+\frac {\cos ^5(c+d x)}{5 b d} \]
[Out]
Time = 0.17 (sec) , antiderivative size = 177, normalized size of antiderivative = 1.00, number of steps used = 6, number of rules used = 5, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.208, Rules used = {3294, 1184, 1107, 211, 214} \[ \int \frac {\sin ^9(c+d x)}{a-b \sin ^4(c+d x)} \, dx=-\frac {a^{3/2} \arctan \left (\frac {\sqrt [4]{b} \cos (c+d x)}{\sqrt {\sqrt {a}-\sqrt {b}}}\right )}{2 b^{9/4} d \sqrt {\sqrt {a}-\sqrt {b}}}-\frac {a^{3/2} \text {arctanh}\left (\frac {\sqrt [4]{b} \cos (c+d x)}{\sqrt {\sqrt {a}+\sqrt {b}}}\right )}{2 b^{9/4} d \sqrt {\sqrt {a}+\sqrt {b}}}+\frac {(a+b) \cos (c+d x)}{b^2 d}+\frac {\cos ^5(c+d x)}{5 b d}-\frac {2 \cos ^3(c+d x)}{3 b d} \]
[In]
[Out]
Rule 211
Rule 214
Rule 1107
Rule 1184
Rule 3294
Rubi steps \begin{align*} \text {integral}& = -\frac {\text {Subst}\left (\int \frac {\left (1-x^2\right )^4}{a-b+2 b x^2-b x^4} \, dx,x,\cos (c+d x)\right )}{d} \\ & = -\frac {\text {Subst}\left (\int \left (-\frac {a+b}{b^2}+\frac {2 x^2}{b}-\frac {x^4}{b}+\frac {a^2}{b^2 \left (a-b+2 b x^2-b x^4\right )}\right ) \, dx,x,\cos (c+d x)\right )}{d} \\ & = \frac {(a+b) \cos (c+d x)}{b^2 d}-\frac {2 \cos ^3(c+d x)}{3 b d}+\frac {\cos ^5(c+d x)}{5 b d}-\frac {a^2 \text {Subst}\left (\int \frac {1}{a-b+2 b x^2-b x^4} \, dx,x,\cos (c+d x)\right )}{b^2 d} \\ & = \frac {(a+b) \cos (c+d x)}{b^2 d}-\frac {2 \cos ^3(c+d x)}{3 b d}+\frac {\cos ^5(c+d x)}{5 b d}+\frac {a^{3/2} \text {Subst}\left (\int \frac {1}{-\sqrt {a} \sqrt {b}+b-b x^2} \, dx,x,\cos (c+d x)\right )}{2 b^{3/2} d}-\frac {a^{3/2} \text {Subst}\left (\int \frac {1}{\sqrt {a} \sqrt {b}+b-b x^2} \, dx,x,\cos (c+d x)\right )}{2 b^{3/2} d} \\ & = -\frac {a^{3/2} \arctan \left (\frac {\sqrt [4]{b} \cos (c+d x)}{\sqrt {\sqrt {a}-\sqrt {b}}}\right )}{2 \sqrt {\sqrt {a}-\sqrt {b}} b^{9/4} d}-\frac {a^{3/2} \text {arctanh}\left (\frac {\sqrt [4]{b} \cos (c+d x)}{\sqrt {\sqrt {a}+\sqrt {b}}}\right )}{2 \sqrt {\sqrt {a}+\sqrt {b}} b^{9/4} d}+\frac {(a+b) \cos (c+d x)}{b^2 d}-\frac {2 \cos ^3(c+d x)}{3 b d}+\frac {\cos ^5(c+d x)}{5 b d} \\ \end{align*}
Result contains higher order function than in optimal. Order 9 vs. order 3 in optimal.
Time = 2.67 (sec) , antiderivative size = 228, normalized size of antiderivative = 1.29 \[ \int \frac {\sin ^9(c+d x)}{a-b \sin ^4(c+d x)} \, dx=\frac {\cos (c+d x) (120 a+89 b-28 b \cos (2 (c+d x))+3 b \cos (4 (c+d x)))+60 i a^2 \text {RootSum}\left [b-4 b \text {$\#$1}^2-16 a \text {$\#$1}^4+6 b \text {$\#$1}^4-4 b \text {$\#$1}^6+b \text {$\#$1}^8\&,\frac {-2 \arctan \left (\frac {\sin (c+d x)}{\cos (c+d x)-\text {$\#$1}}\right ) \text {$\#$1}+i \log \left (1-2 \cos (c+d x) \text {$\#$1}+\text {$\#$1}^2\right ) \text {$\#$1}+2 \arctan \left (\frac {\sin (c+d x)}{\cos (c+d x)-\text {$\#$1}}\right ) \text {$\#$1}^3-i \log \left (1-2 \cos (c+d x) \text {$\#$1}+\text {$\#$1}^2\right ) \text {$\#$1}^3}{-b-8 a \text {$\#$1}^2+3 b \text {$\#$1}^2-3 b \text {$\#$1}^4+b \text {$\#$1}^6}\&\right ]}{120 b^2 d} \]
[In]
[Out]
Time = 2.97 (sec) , antiderivative size = 137, normalized size of antiderivative = 0.77
method | result | size |
derivativedivides | \(\frac {\frac {\frac {b \left (\cos ^{5}\left (d x +c \right )\right )}{5}-\frac {2 b \left (\cos ^{3}\left (d x +c \right )\right )}{3}+\cos \left (d x +c \right ) a +\cos \left (d x +c \right ) b}{b^{2}}+\frac {a^{2} \left (-\frac {\operatorname {arctanh}\left (\frac {\cos \left (d x +c \right ) b}{\sqrt {\left (\sqrt {a b}+b \right ) b}}\right )}{2 \sqrt {a b}\, \sqrt {\left (\sqrt {a b}+b \right ) b}}-\frac {\arctan \left (\frac {\cos \left (d x +c \right ) b}{\sqrt {\left (\sqrt {a b}-b \right ) b}}\right )}{2 \sqrt {a b}\, \sqrt {\left (\sqrt {a b}-b \right ) b}}\right )}{b}}{d}\) | \(137\) |
default | \(\frac {\frac {\frac {b \left (\cos ^{5}\left (d x +c \right )\right )}{5}-\frac {2 b \left (\cos ^{3}\left (d x +c \right )\right )}{3}+\cos \left (d x +c \right ) a +\cos \left (d x +c \right ) b}{b^{2}}+\frac {a^{2} \left (-\frac {\operatorname {arctanh}\left (\frac {\cos \left (d x +c \right ) b}{\sqrt {\left (\sqrt {a b}+b \right ) b}}\right )}{2 \sqrt {a b}\, \sqrt {\left (\sqrt {a b}+b \right ) b}}-\frac {\arctan \left (\frac {\cos \left (d x +c \right ) b}{\sqrt {\left (\sqrt {a b}-b \right ) b}}\right )}{2 \sqrt {a b}\, \sqrt {\left (\sqrt {a b}-b \right ) b}}\right )}{b}}{d}\) | \(137\) |
risch | \(\frac {a \,{\mathrm e}^{i \left (d x +c \right )}}{2 d \,b^{2}}+\frac {5 \,{\mathrm e}^{i \left (d x +c \right )}}{16 b d}+\frac {{\mathrm e}^{-i \left (d x +c \right )} a}{2 b^{2} d}+\frac {5 \,{\mathrm e}^{-i \left (d x +c \right )}}{16 b d}-\frac {i \left (\munderset {\textit {\_R} =\operatorname {RootOf}\left (\left (a \,b^{9} d^{4}-b^{10} d^{4}\right ) \textit {\_Z}^{4}-32768 a^{3} b^{5} d^{2} \textit {\_Z}^{2}-268435456 a^{6}\right )}{\sum }\textit {\_R} \ln \left ({\mathrm e}^{2 i \left (d x +c \right )}+\left (\left (-\frac {i b^{7} d^{3}}{1048576 a^{4}}+\frac {i b^{8} d^{3}}{1048576 a^{5}}\right ) \textit {\_R}^{3}+\left (\frac {i b^{2} d}{64 a}+\frac {i b^{3} d}{64 a^{2}}\right ) \textit {\_R} \right ) {\mathrm e}^{i \left (d x +c \right )}+1\right )\right )}{512}+\frac {\cos \left (5 d x +5 c \right )}{80 b d}-\frac {5 \cos \left (3 d x +3 c \right )}{48 b d}\) | \(231\) |
[In]
[Out]
Leaf count of result is larger than twice the leaf count of optimal. 872 vs. \(2 (133) = 266\).
Time = 0.34 (sec) , antiderivative size = 872, normalized size of antiderivative = 4.93 \[ \int \frac {\sin ^9(c+d x)}{a-b \sin ^4(c+d x)} \, dx=\frac {12 \, b \cos \left (d x + c\right )^{5} - 15 \, b^{2} d \sqrt {-\frac {{\left (a b^{4} - b^{5}\right )} \sqrt {\frac {a^{7}}{{\left (a^{2} b^{9} - 2 \, a b^{10} + b^{11}\right )} d^{4}}} d^{2} + a^{3}}{{\left (a b^{4} - b^{5}\right )} d^{2}}} \log \left (a^{5} \cos \left (d x + c\right ) + {\left (a^{4} b^{2} d - {\left (a b^{7} - b^{8}\right )} \sqrt {\frac {a^{7}}{{\left (a^{2} b^{9} - 2 \, a b^{10} + b^{11}\right )} d^{4}}} d^{3}\right )} \sqrt {-\frac {{\left (a b^{4} - b^{5}\right )} \sqrt {\frac {a^{7}}{{\left (a^{2} b^{9} - 2 \, a b^{10} + b^{11}\right )} d^{4}}} d^{2} + a^{3}}{{\left (a b^{4} - b^{5}\right )} d^{2}}}\right ) + 15 \, b^{2} d \sqrt {\frac {{\left (a b^{4} - b^{5}\right )} \sqrt {\frac {a^{7}}{{\left (a^{2} b^{9} - 2 \, a b^{10} + b^{11}\right )} d^{4}}} d^{2} - a^{3}}{{\left (a b^{4} - b^{5}\right )} d^{2}}} \log \left (a^{5} \cos \left (d x + c\right ) - {\left (a^{4} b^{2} d + {\left (a b^{7} - b^{8}\right )} \sqrt {\frac {a^{7}}{{\left (a^{2} b^{9} - 2 \, a b^{10} + b^{11}\right )} d^{4}}} d^{3}\right )} \sqrt {\frac {{\left (a b^{4} - b^{5}\right )} \sqrt {\frac {a^{7}}{{\left (a^{2} b^{9} - 2 \, a b^{10} + b^{11}\right )} d^{4}}} d^{2} - a^{3}}{{\left (a b^{4} - b^{5}\right )} d^{2}}}\right ) + 15 \, b^{2} d \sqrt {-\frac {{\left (a b^{4} - b^{5}\right )} \sqrt {\frac {a^{7}}{{\left (a^{2} b^{9} - 2 \, a b^{10} + b^{11}\right )} d^{4}}} d^{2} + a^{3}}{{\left (a b^{4} - b^{5}\right )} d^{2}}} \log \left (-a^{5} \cos \left (d x + c\right ) + {\left (a^{4} b^{2} d - {\left (a b^{7} - b^{8}\right )} \sqrt {\frac {a^{7}}{{\left (a^{2} b^{9} - 2 \, a b^{10} + b^{11}\right )} d^{4}}} d^{3}\right )} \sqrt {-\frac {{\left (a b^{4} - b^{5}\right )} \sqrt {\frac {a^{7}}{{\left (a^{2} b^{9} - 2 \, a b^{10} + b^{11}\right )} d^{4}}} d^{2} + a^{3}}{{\left (a b^{4} - b^{5}\right )} d^{2}}}\right ) - 15 \, b^{2} d \sqrt {\frac {{\left (a b^{4} - b^{5}\right )} \sqrt {\frac {a^{7}}{{\left (a^{2} b^{9} - 2 \, a b^{10} + b^{11}\right )} d^{4}}} d^{2} - a^{3}}{{\left (a b^{4} - b^{5}\right )} d^{2}}} \log \left (-a^{5} \cos \left (d x + c\right ) - {\left (a^{4} b^{2} d + {\left (a b^{7} - b^{8}\right )} \sqrt {\frac {a^{7}}{{\left (a^{2} b^{9} - 2 \, a b^{10} + b^{11}\right )} d^{4}}} d^{3}\right )} \sqrt {\frac {{\left (a b^{4} - b^{5}\right )} \sqrt {\frac {a^{7}}{{\left (a^{2} b^{9} - 2 \, a b^{10} + b^{11}\right )} d^{4}}} d^{2} - a^{3}}{{\left (a b^{4} - b^{5}\right )} d^{2}}}\right ) - 40 \, b \cos \left (d x + c\right )^{3} + 60 \, {\left (a + b\right )} \cos \left (d x + c\right )}{60 \, b^{2} d} \]
[In]
[Out]
Timed out. \[ \int \frac {\sin ^9(c+d x)}{a-b \sin ^4(c+d x)} \, dx=\text {Timed out} \]
[In]
[Out]
\[ \int \frac {\sin ^9(c+d x)}{a-b \sin ^4(c+d x)} \, dx=\int { -\frac {\sin \left (d x + c\right )^{9}}{b \sin \left (d x + c\right )^{4} - a} \,d x } \]
[In]
[Out]
\[ \int \frac {\sin ^9(c+d x)}{a-b \sin ^4(c+d x)} \, dx=\int { -\frac {\sin \left (d x + c\right )^{9}}{b \sin \left (d x + c\right )^{4} - a} \,d x } \]
[In]
[Out]
Time = 14.43 (sec) , antiderivative size = 1067, normalized size of antiderivative = 6.03 \[ \int \frac {\sin ^9(c+d x)}{a-b \sin ^4(c+d x)} \, dx=\frac {{\cos \left (c+d\,x\right )}^5}{5\,b\,d}-\frac {2\,{\cos \left (c+d\,x\right )}^3}{3\,b\,d}+\frac {\cos \left (c+d\,x\right )\,\left (\frac {a-b}{b^2}+\frac {2}{b}\right )}{d}+\frac {\mathrm {atan}\left (-\frac {a^4\,\cos \left (c+d\,x\right )\,\sqrt {-\frac {\sqrt {a^7\,b^9}}{16\,\left (a\,b^9-b^{10}\right )}-\frac {a^3\,b^5}{16\,\left (a\,b^9-b^{10}\right )}}\,8{}\mathrm {i}}{\frac {2\,a^6\,b^7}{a\,b^9-b^{10}}+\frac {2\,a^3\,b^2\,\sqrt {a^7\,b^9}}{a\,b^9-b^{10}}}+\frac {a^4\,b^9\,\cos \left (c+d\,x\right )\,\sqrt {-\frac {\sqrt {a^7\,b^9}}{16\,\left (a\,b^9-b^{10}\right )}-\frac {a^3\,b^5}{16\,\left (a\,b^9-b^{10}\right )}}\,8{}\mathrm {i}}{\frac {2\,a^6\,b^{16}}{a\,b^9-b^{10}}-\frac {2\,a^7\,b^{15}}{a\,b^9-b^{10}}+\frac {2\,a^3\,b^{11}\,\sqrt {a^7\,b^9}}{a\,b^9-b^{10}}-\frac {2\,a^4\,b^{10}\,\sqrt {a^7\,b^9}}{a\,b^9-b^{10}}}+\frac {a\,b^4\,\cos \left (c+d\,x\right )\,\sqrt {-\frac {\sqrt {a^7\,b^9}}{16\,\left (a\,b^9-b^{10}\right )}-\frac {a^3\,b^5}{16\,\left (a\,b^9-b^{10}\right )}}\,\sqrt {a^7\,b^9}\,8{}\mathrm {i}}{\frac {2\,a^6\,b^{16}}{a\,b^9-b^{10}}-\frac {2\,a^7\,b^{15}}{a\,b^9-b^{10}}+\frac {2\,a^3\,b^{11}\,\sqrt {a^7\,b^9}}{a\,b^9-b^{10}}-\frac {2\,a^4\,b^{10}\,\sqrt {a^7\,b^9}}{a\,b^9-b^{10}}}\right )\,\sqrt {-\frac {\sqrt {a^7\,b^9}+a^3\,b^5}{16\,\left (a\,b^9-b^{10}\right )}}\,2{}\mathrm {i}}{d}-\frac {\mathrm {atan}\left (\frac {a^4\,\cos \left (c+d\,x\right )\,\sqrt {\frac {\sqrt {a^7\,b^9}}{16\,\left (a\,b^9-b^{10}\right )}-\frac {a^3\,b^5}{16\,\left (a\,b^9-b^{10}\right )}}\,8{}\mathrm {i}}{\frac {2\,a^6\,b^7}{a\,b^9-b^{10}}-\frac {2\,a^3\,b^2\,\sqrt {a^7\,b^9}}{a\,b^9-b^{10}}}-\frac {a^4\,b^9\,\cos \left (c+d\,x\right )\,\sqrt {\frac {\sqrt {a^7\,b^9}}{16\,\left (a\,b^9-b^{10}\right )}-\frac {a^3\,b^5}{16\,\left (a\,b^9-b^{10}\right )}}\,8{}\mathrm {i}}{\frac {2\,a^6\,b^{16}}{a\,b^9-b^{10}}-\frac {2\,a^7\,b^{15}}{a\,b^9-b^{10}}-\frac {2\,a^3\,b^{11}\,\sqrt {a^7\,b^9}}{a\,b^9-b^{10}}+\frac {2\,a^4\,b^{10}\,\sqrt {a^7\,b^9}}{a\,b^9-b^{10}}}+\frac {a\,b^4\,\cos \left (c+d\,x\right )\,\sqrt {\frac {\sqrt {a^7\,b^9}}{16\,\left (a\,b^9-b^{10}\right )}-\frac {a^3\,b^5}{16\,\left (a\,b^9-b^{10}\right )}}\,\sqrt {a^7\,b^9}\,8{}\mathrm {i}}{\frac {2\,a^6\,b^{16}}{a\,b^9-b^{10}}-\frac {2\,a^7\,b^{15}}{a\,b^9-b^{10}}-\frac {2\,a^3\,b^{11}\,\sqrt {a^7\,b^9}}{a\,b^9-b^{10}}+\frac {2\,a^4\,b^{10}\,\sqrt {a^7\,b^9}}{a\,b^9-b^{10}}}\right )\,\sqrt {\frac {\sqrt {a^7\,b^9}-a^3\,b^5}{16\,\left (a\,b^9-b^{10}\right )}}\,2{}\mathrm {i}}{d} \]
[In]
[Out]